<%--
  Created by IntelliJ IDEA.
  User: zhangkeke
  Date: 2022/10/11
  Time: 16:30
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false" %>
<html>
<head>
    <title>绑卡</title>
    <script src="${pageContext.request.contextPath}/jcript/jquery-1.7.2.js"></script>
    <script>
        $(function (){
            $("#btn").click(function (){
                var username = $("#inp1").val()
                var id_card = $("#inp2").val()
                var telephone = $("#inp3").val()
                $.ajax({
                    data:{username:username,id_card:id_card,telephone:telephone},
                    dataType:"json",
                    url:"/card_binding",
                    success:function (data){
                        if(data==1){
                               location.href="/pages/userMenu.jsp"
                        }

                    }
                })
            })
        })
    </script>

</head>
<body>
<div style="position: relative;left: 550px;top: 150px">
    <h3>绑卡</h3>
    <label>用户名</label>
    <input type="text" id="inp1" name="username">
    <label>银行卡号</label>
    <input type="text" id="inp2" name="id_card">
    <label>银行卡预留手机号</label>
    <input type="text" id="inp3" name="telephone">
    <button id="btn">绑卡</button>
</div>


</body>
</html>
